<?php
use yii\helpers\Html;
use yii\widgets\ActiveForm;
use yii\captcha\Captcha;
use yii\helpers\Url;
?>
<?php $form=ActiveForm::begin([//表单开始
    'enableClientValidation'=>true,//是否启用客户端验证
    'id'=>'login-form',
    'method'=>'post',//提交方式
    'options' => ['class' => 'login-form']//自定义样式
]);?>
<?= $form->field($model, 'user')->textInput(['class'=>'user','placeholder'=>'请输入用户名']); ?>
<?= $form->field($model, 'password')->passwordInput(['class'=>'password','placeholder'=>'请输入密码']); ?>
<?= Html::submitButton('登&nbsp;&nbsp;录',['class'=>'submit']) ?>
<a class="fail" href="<?= Url::to(['reset/index']);?>">忘记密码 ?</a>
<?php
ActiveForm::end();//表单结束
?>
